<?php
App::uses('ShellDispatcher', 'Console');

class CreateController extends AppController
{
    public $name = "Create";
	public $uses = array("account");
    public $autoRender = false;

	public function index()
    {
        pr(1);
        //http://192.168.0.201/push-server/create/push?push_id=123123123&os=android
        //$this->autoRender = FALSE;
        //pr($_GET);

        $data = "<>aaa bbb ccc";
        pr(str_replace(array("<",">", " "), "", $data));

	}

    public function push()
    {
        if(empty($_GET['push_id']) && empty($_GET['os']))
        {
            return false;
        }

        $data = array();
        $data['push_id'] = $_GET["push_id"];
        $data['os'] = $_GET['os'];

        $data['push_id'] = str_replace(array("<", ">", " "), "", $data['push_id']);

        if(!$this->account->user_create($data))
        {
            pr($this->name . ' => Line : ' .  __LINE__);
            return false;
        }
    }

}
